home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 3: Developer Tools / Linux Cubed Series 3 - Developer Tools.iso / utils / terminal / qterm-6.0 / qterm-6 / Makefile < prev    next >
Encoding:
Makefile  |  1993-07-28  |  2.5 KB  |  117 lines

  1. #
  2. # Copyright (c) 1990-1993 Michael A. Cooper.
  3. # This software may be freely distributed provided it is not sold for 
  4. # profit and the author is credited appropriately.
  5. #
  6. # $Id: Makefile,v 6.8 1993/07/28 21:16:06 mcooper Exp mcooper $
  7. #
  8. # Makefile for QTerm
  9. #
  10. # To compile, run one of the following:
  11. #
  12. #     COMMAND            SYSTEM TYPE
  13. #     make            4.x BSD
  14. #     make svr4        System V Release 4 (SVR4)
  15. #     make sysv        Older System V Releases (prior to SVR4)
  16. #
  17.  
  18. #
  19. # DIR is the main/top-level directory.
  20. # If you change DIR, run "make reconfig".
  21. #
  22. DIR     = /usr/local
  23.  
  24. #
  25. # BIN is were the "qterm" binary gets installed.
  26. #
  27. BIN     = $(DIR)/bin
  28.  
  29. #
  30. # MAN is the directory where the "qterm.1" man page goes.
  31. #
  32. MAN     = $(DIR)/man/man1
  33.  
  34. #
  35. # TABFILE should be set to the location you want the qterm table
  36. # file placed in.
  37. #
  38. TABFILE = $(DIR)/lib/qtermtab
  39.  
  40. #
  41. # Name of your BSD-like install program.
  42. # Use "./bsdinst.sh" if you don't have one.
  43. #
  44. INSTALL    = install
  45.  
  46. ##############################################################################
  47. #
  48. #     End of Normal system configuration
  49. #
  50. ##############################################################################
  51.  
  52. #
  53. # Add "-DSYSV" to OSDEFS below, if your system is Unix System V.
  54. # Add "-D_POSIX_SOURCE" to OSDEFS below, if your system is POSIX compliant.
  55. # Add "-DHAVE_VARARGS" if your system supports varargs.
  56. # Add "-DOPT_COMPAT" if you want compatibility with old command line options.
  57. #
  58. OSDEFS    = -DHAVE_VARARGS
  59.  
  60. #
  61. # On some System V (Releases up through 3) systems you will need 
  62. # to add "-lPW" to LIBS.
  63. #
  64. # On System V Release 4 systems, like Solaris 2.x (SunOS 5.x), 
  65. # you need "-lgen".
  66. #
  67. LIBS    =
  68.  
  69.  
  70. CONFIGFILES    = Makefile qterm.1 options.3
  71. HFILES        = config-data.h config.h options.h qterm.h version.h
  72. OBJS         = qterm.o aux.o table.o tty.o signals.o options.o
  73. OPT        = -O
  74. DEFS         = -DTABFILE=\"$(TABFILE)\" $(OSDEFS)
  75. CFLAGS         = $(OPT) $(DEFS)
  76.  
  77. qterm: $(OBJS) $(HFILES)
  78.     $(CC) $(CFLAGS) $(OBJS) -o qterm $(LIBS)
  79.  
  80. reconfig:
  81.     -@for i in $(CONFIGFILES); do \
  82.                 echo ReConfiguring $$i...;\
  83.         sed "s;/usr/usc;$(DIR);g" < $$i > $$i.tmp;\
  84.         mv -f $$i.tmp $$i;\
  85.         done
  86.  
  87. $(OBJS): $(HFILES)
  88.  
  89. clean:
  90.     rm -f *.o core log *~ \#* qterm qterm.shar o $(OBJS)
  91.  
  92. #
  93. # Install files
  94. #
  95. install: qterm qtermtab
  96.     $(INSTALL) -c -m 755 qterm $(BIN)
  97.     $(INSTALL) -c -m 644 qtermtab $(TABFILE)
  98.  
  99. install.man: qterm.1
  100.     $(INSTALL) -c -m 644 qterm.1 $(MAN)
  101.  
  102. #
  103. # OS submakes
  104. #
  105.  
  106. #
  107. # System V Release 4
  108. #
  109. svr4 SVR4 sunos5 SUNOS5 solaris2 SOLARIS2:
  110.     make 'OSDEFS=-DSYSV -D_POSIX_SOURCE' LIBS=-lgen
  111.  
  112. #
  113. # System V Releases up through 3
  114. #
  115. sysv SYSV hpux HPUX:
  116.     make 'OSDEFS=-DSYSV -DHAVE_VARARGS' LIBS=-lPW
  117.